home *** CD-ROM | disk | FTP | other *** search
/ The 640 MEG Shareware Studio 2 / The 640 Meg Shareware Studio CD-ROM Volume II (Data Express)(1993).ISO / pascal / tj50dsk2.zip / UPGRADE.DOC < prev    next >
Text File  |  1989-01-31  |  5KB  |  150 lines

  1.  
  2.         U P G R A D E   N O T E S   F O R   V E R S I O N   4   U S E R S
  3.         -----------------------------------------------------------------
  4.  
  5. This file contains important information for programmers who are upgrading
  6. an application from version 4.0 to version 5.0 of the Toolkit.
  7.  
  8. During development of the new Toolkit, every effort has been made to maintain
  9. consistency with version 4.0, but in certain units this was not possible.
  10. As a result, some programs that were written for version 4.0 will need to be
  11. modified before they will function with the new version. This document does
  12. not identify any of the new additions to the Toolkit, only changes to 
  13. existing routines.
  14.  
  15. Listed below, in order of significance, are the details for each unit:
  16.  
  17. IOTTT5
  18. ------
  19.  
  20. This unit has undergone a very major rewrite with many new powerful features.
  21. In order for the expanded IO routines to be consistent, all of the old
  22. procedures have been renamed. The table below identifies the v4.0
  23. procedure with the corresponding v5.0 procedure(s).
  24.  
  25.                Version 4.0               Version 5.0
  26.  
  27.               IO_SetFields              Create_Fields
  28.               IO_SetColors              Define_Colors
  29.               IO_DefineMsg              Add_Message
  30.               IO_DefineStr              Add_Field + String_Field
  31.               IO_DisplayFields          Display_All_Fields
  32.               IO_SoundBeeper            Allow_Beep
  33.               IO_ResetFields            Dispose_Fields
  34.               IO_AllowEsc               Allow_Esc
  35.               IO_Edit                   Process_Input
  36.  
  37. The Process_Input procedure is passed a parameter that identifies the field
  38. number of the first field to highlight - not an error code. The variable
  39. I_Char is updated with the character that the user pressed last. I_Char
  40. will be set to #027 if the user escaped.
  41.  
  42. Listed below is a code fragment that has been converted from v4.0 to v5.0:
  43.  
  44.  
  45. {Version 4.0 commands}
  46. begin
  47.     IO_SetFields(3);
  48.     IO_SoundBeeper(False);
  49.     IO_DefineStr(1,  3, 2, 3, 2, 25, 1, Str1, '!!!!!!!!!!!!!!!!!!!!!!');
  50.     IO_DefineStr(2,  1, 3, 1, 3, 25, 3, Str2, '###');
  51.     IO_DefineStr(3,  2, 1, 2, 1, 25, 5, Str3, '(##-###) ##');
  52.     SaveScreen(1);                     {save previous input screen}
  53.     Attrib(1,1,80,25,darkgray,black);  {darken the display but still visible}
  54.     FBox(X1,Y1,X2,Y2,blue,lightgray,1);
  55.     WriteAT(1,1,blue,lightgray,'Order description:');
  56.     WriteAT(1,3,blue,lightgray,'Quantity:');
  57.     WriteAT(1,5,blue,lightgray,'Part No:');
  58.     IO_Edit(Retcode);
  59.     IO_ResetFields;
  60.     RestoreScreen(1);
  61.     DisposeScreen(1);
  62. end;
  63.  
  64.  
  65. {equivalent version 5.0 commands}
  66. begin
  67.     Create_Fields(3);
  68.     Allow_Beep(False);
  69.     Add_Field(1,    3, 2, 3, 2, 25, 1);
  70.     String_Field(1, Str1, '!!!!!!!!!!!!!!!!!!!!!!');
  71.     Add_Field(2,  1, 3, 1, 3, 25, 3);
  72.     String_Field(2, Str2, '###');
  73.     Add_Field(3,  2, 1, 2, 1, 25, 5);
  74.     String_Field(3, Str3, '(##-###) ##');
  75.     SaveScreen(1);                     {save previous input screen}
  76.     Attrib(1,1,80,25,darkgray,black);  {darken the display but still visible}
  77.     FBox(X1,Y1,X2,Y2,blue,lightgray,1);
  78.     WriteAT(1,1,blue,lightgray,'Order description:');
  79.     WriteAT(1,3,blue,lightgray,'Quantity:');
  80.     WriteAT(1,5,blue,lightgray,'Part No:');
  81.     Process_Input(1);
  82.     Dispose_Fields;
  83.     RestoreScreen(1);
  84.     DisposeScreen(1);
  85. end;
  86.  
  87. Review the IODEM?.pas files for more further examples of the new commands.
  88.  
  89. Set a conditional define IOFULL to enable all of the new features.
  90.  
  91.  
  92. MenuTTT5
  93. --------
  94.  
  95. A new procedure Menu_Set has been added. This procedure automatically
  96. sets a menu_record variable to its default values. You MUST call this 
  97. procedure to initialize the menu_record variables, otherwise the system
  98. will hang. 
  99.  
  100. The major change is that a user hook has been added to the menu_record, and
  101. it needs to be set to nil or to a far procedure. Refer to menudem1.pas
  102. for a simple example.
  103.  
  104.  
  105. DirTTT5
  106. -------
  107.  
  108. This unit has been completely rewritten. The Display_Directory procedure
  109. is now passed the fully qualified file mask instead of the path and filemask 
  110. separately.
  111.  
  112. The global variable "DTTT" (formerly "D") controls the look and feel of the
  113. directory window.
  114.  
  115. Set a conditional define DIRFULL to enable all of the directory procedures.
  116.  
  117.  
  118. WinTTT5
  119. -------
  120. A new global boolean variable W_Fatal is used to identify if the program will
  121. halt when a window error occurs. Another global variable W_Error is updated
  122. with the error codes after window operations.
  123.  
  124. The Screen_Size parameter is no longer needed. The Toolkit automatically
  125. accommodates condensed screen displays.
  126.  
  127.  
  128. MiscTTT5
  129. --------
  130. The function Exist can now be passed a file mask as well as a specific
  131. filename.
  132.  
  133.  
  134. FastTTT5
  135. --------
  136. The global variable WaitForRetrace has been renamed SnowProne.
  137.  
  138.  
  139. PullTTT5
  140. --------
  141. The global variable PM has been renamed PTTT.
  142.  
  143.  
  144. The v4.0 structure of the routines in KeyTTT5, readTTT5 and StrnTTT5 
  145. have not been affected.
  146.  
  147.  
  148.                                -- o --
  149.  
  150.